home *** CD-ROM | disk | FTP | other *** search
/ Power Programmierung 2 / Power-Programmierung CD 2 (Tewi)(1994).iso / c / tools / make / cmake / samples / cmdequiv / makefile < prev    next >
Encoding:
Makefile  |  1991-11-16  |  1.5 KB  |  43 lines

  1. /*****************************************************************************
  2. *                              MAKEFILE
  3. *
  4. *  PURPOSE: Create the file, "2.txt", by sorting the file, "1.txt".
  5. *           Create the file, "3.txt", by extracting all the lines from
  6. *           the file, "2.txt", that contain the word "toad".
  7. *
  8. *  NOTE: None of the comments in this make file are required.  They have
  9. *        been provided to help you understand how CMAKE handles each
  10. *        command.  In other words, this make file could be reduced down to
  11. *        the following two commands:
  12. *
  13. *        sort <1.txt >2.txt
  14. *        find "toad" <2.txt >3.txt
  15. *
  16. *****************************************************************************/
  17.  
  18. /*****************************************************************************
  19. *                                 2.TXT
  20. *
  21. *  The following SORT command will be executed only when one of the
  22. *  following conditions is true:
  23. *
  24. *  1. "2.txt" does not exist.
  25. *  2. "1.txt" is newer than "2.txt".
  26. *
  27. *****************************************************************************/
  28.  
  29. sort <1.txt >2.txt
  30.  
  31. /*****************************************************************************
  32. *                                 3.TXT
  33. *
  34. *  The following FIND command will be executed only when one of the
  35. *  following conditions is true:
  36. *
  37. *  1. "3.txt" does not exist.
  38. *  2. "2.txt" is newer than "3.txt".
  39. *
  40. *****************************************************************************/
  41.  
  42. find "toad" <2.txt >3.txt
  43.